The attached trivial patch fixes cases where a block device is mounted
authorkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Thu, 30 Mar 2006 15:53:37 +0000 (16:53 +0100)
committerkaf24@firebug.cl.cam.ac.uk <kaf24@firebug.cl.cam.ac.uk>
Thu, 30 Mar 2006 15:53:37 +0000 (16:53 +0100)
read-only in domain 0, but still fails to be shared with a domU, because
it is mis-identified as being mounted writable.  (On SUSE, CDs and DVDs
are auto-mounted not with merely permissions "ro", but
"ro,nosuid,nodev", hence the mis-identification.)

Signed-off-by: Charles Coffing <ccoffing@novell.com>
tools/examples/block

index 5a43560eff8a34b1569d8311a27bb4c7ba5b2a79..dae32dc2345b92a98ac142ea683450125422fd92 100644 (file)
@@ -72,7 +72,7 @@ check_sharing()
   then
     toskip="^$"
   else
-    toskip="^[^ ]* [^ ]* [^ ]* ro "
+    toskip="^[^ ]* [^ ]* [^ ]* ro[, ]"
   fi
 
   for file in $(cat /proc/mounts | grep -v "$toskip" | cut -f 1 -d ' ')